#ifndef _BUFFER_H
#define	_BUFFER_H

#include <vector>

namespace obj {

    struct buffer {
        buffer(unsigned buffersize);

        typedef std::vector<char> Container;

        Container buf;
        unsigned cursor;
        unsigned length;
        unsigned buffersize;

        void increase(unsigned n);
        void increase();

        char next();
    };
}

#endif	/* _BUFFER_H */

